package com.ruoyi.system.config;

import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.socket.server.standard.ServerEndpointExporter;

@Configuration
@Slf4j
public class WebSocketConfig {
    // 注册WebSocket端点，使Spring能够处理WebSocket请求
    @Bean
    public ServerEndpointExporter serverEndpointExporter() {
        log.info("WebSocket端点注册器已初始化");
        return new ServerEndpointExporter();
    }
}